<template>
<div>
  <a-modal
    title="消息全文"
    :keyboard="true"
    :maskClosable="true"
    :closable="false"
    v-model="show"
    @cancel="close"
    :confirmLoading="loading">
    <span>{{message}}</span>
    <template slot="footer">
      <a-button @click="close">
        关闭
      </a-button>
    </template>
  </a-modal>
</div>
</template>
<script>

export default {
  props: {
    visible: {
      default: false
    }
  },
  data () {
    return {
      message: null,
      loading: false
    }
  },
  computed: {
    show: {
      get: function () {
        return this.visible
      },
      set: function () {
      }
    }
  },
  methods: {
    close () {
      this.message = null
      this.$emit('cancel')
    },
    setMessage (msg) {
      this.message = msg
    }
  }
}
</script>
